Field of the Invention
The present invention relates to name resolution in a network.
Description of the Related Art
A large number of communication terminals have TCP/IP communication function in recent years. For communication between these communication terminals, an individual IP address needs to be assigned to each terminal, in order to identify the other apparatus in communication on a network. On the other hand, for the convenience of users of communication terminals, for example, not an IP address but a domain name corresponding to the IP address is often used to specify the other apparatus in communication. In the case of using the domain name, the IP address corresponding to the domain name is specified by name resolution according to the Domain Name System (DNS) and used for communication.
A communication terminal can cache (temporarily store) an IP address obtained as a result of designating a domain name and requesting name resolution, in association with the corresponding domain name (see RFC 1035 DOMAIN NAMES—IMPLEMENTATION AND SPECIFICATION (URL: http://www.ietf.org/rfc/rfc1035.txt)). This cache function saves the need for the communication terminal to repeat a name resolution request for the same domain name, and shortens the response time of name resolution or reduces network traffic.
A certain amount of memory needs to be reserved to cache a name resolution result. In an embedded device where resources such as memory are limited, dynamically reserving the memory for the cache may cause an increase in processing load or a lack of available resources for other applications. Accordingly, a preset size of memory is often reserved to cache name resolution results. The size of memory needed to cache domain names is “(the maximum domain name length (255 characters))×(the number of domain names allowed to be stored)”. Actually, however, not many domain names have 255 characters. There is thus a problem in that memory resources are wasted in an embedded device which operates with limited memory.
The present invention has been made in view of the problem stated above, and provides a technique for preventing waste of storage space in temporary storage of name resolution results.